package com.ethink.order.common.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import java.util.Date;
import java.math.BigDecimal;
import com.ethink.framework.common.db.SuperEntity;

/**
 * 采购单 数据库实体
 *
 * @author default
 * @date 2022-10-31
 */
@Data
@TableName("t_purchase_order")
public class PurchaseOrder extends SuperEntity {

    public static final String ORDER_NO ="order_no";

    public static final String SALE_DEMAND_ORDER_NO ="sale_demand_order_no";

    public static final String ORDER_STATUS ="order_status";

    public static final String SUPPLIER_CODE ="supplier_code";

    public static final String SUPPLIER_NAME ="supplier_name";

    public static final String SUB_WAREHOUSE_CODE ="sub_warehouse_code";

    public static final String SUB_WAREHOUSE_NAME ="sub_warehouse_name";

    public static final String OUT_ORDER_NO ="out_order_no";

    public static final String CREATE_USER_CODE ="create_user_code";

    public static final String CREATE_USER_NAME ="create_user_name";

    public static final String EXCEPT_OUTBOUND_TIME ="except_outbound_time";

    public static final String ORDER_PRICE ="order_price";

    public static final String SHOULD_PAY_AMOUNT ="should_pay_amount";

    public static final String DISCOUNT_AMOUNT ="discount_amount";

    public static final String PREPAY_AMOUNT ="prepay_amount";

    public static final String DISCOUNT_RATE ="discount_rate";

    public static final String REST_AMOUNT ="rest_amount";

    public static final String APPLY_USER ="apply_user";

    public static final String SALE_CHANNEL ="sale_channel";

    public static final String SALE_SUB_CHANNEL ="sale_sub_channel";

    public static final String PAYER_ACCOUNT ="payer_account";

    public static final String PAYER_NAME ="payer_name";

    public static final String BANK_TRADE_NO ="bank_trade_no";

    public static final String BANK_TRADE_REMARK ="bank_trade_remark";

    public static final String PURCHASE_QUALIFICATION ="purchase_qualification";

    public static final String BANK_TRADE_FILE_ID ="bank_trade_file_id";

    public static final String PAY_INVOICE_FILE_ID ="pay_invoice_file_id";

    public static final String CURRENCY_CODE ="currency_code";

    public static final String CURRENCY_NAME ="currency_name";

    public static final String EXCHANGE_RATE ="exchange_rate";

    public static final String SUPPLE_TIME ="supple_time";

    public static final String HAS_PAID ="has_paid";


    /** 采购单号 */
    private String orderNo;

    /** 销售需求单号 */
    private String saleDemandOrderNo;

    /** 枚举 订单状态:1-草稿(s1)|2-待付款(s2)|3-待收货(s3)|4-已完结(s4) */
    private Integer orderStatus;

    /** 供应商编码 */
    private String supplierCode;

    /** 供应商名称 */
    private String supplierName;

    /** 分仓编码 */
    private String subWarehouseCode;

    /** 分仓名称 */
    private String subWarehouseName;

    /** 外部单号 */
    private String outOrderNo;

    /** 制单人账号 */
    private String createUserCode;

    /** 制单人名称 */
    private String createUserName;

    /** 预计出境日期 */
    private Date exceptOutboundTime;

    /** 订单金额 */
    private BigDecimal orderPrice;

    /** 应付金额 */
    private BigDecimal shouldPayAmount;

    /** 优惠金额 */
    private BigDecimal discountAmount;

    /** 预付金额 */
    private BigDecimal prepayAmount;

    /** 折扣(%) */
    private BigDecimal discountRate;

    /** 尾款 */
    private BigDecimal restAmount;

    /** 申请人 */
    private String applyUser;

    /** 订单来源 */
    private String saleChannel;

    /** 订单来源下级 */
    private String saleSubChannel;

    /** 付款方账号 */
    private String payerAccount;

    /** 付款方名称 */
    private String payerName;

    /** 银行流水号 */
    private String bankTradeNo;

    /** 付款备注 */
    private String bankTradeRemark;

    /** 采购资质 */
    private String purchaseQualification;

    /** 银行流水相关凭证 */
    private String bankTradeFileId;

    /** 发票 */
    private String payInvoiceFileId;

    /** 货币编码 */
    private String currencyCode;

    /** 货币名称 */
    private String currencyName;

    /** 汇率 */
    private BigDecimal exchangeRate;

    /** 完善时间 */
    private Date suppleTime;

    /** 是否付款 */
    private Boolean hasPaid;

}
